home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1996 #15
/
Monster Media Number 15 (Monster Media)(July 1996).ISO
/
prog_c
/
cuj0696.zip
/
SCHROEDE.ZIP
/
SPHERE.CPP
< prev
Wrap
C/C++ Source or Header
|
1996-03-26
|
612b
|
31 lines
#include "vtk.hh"
main ()
{
vtkRenderMaster rm;
vtkRenderWindow *renWin=rm.MakeRenderWindow();
vtkRenderer *aren=renWin->MakeRenderer();
vtkRenderWindowInteractor *iren=renWin->MakeRenderWindowInteractor();
// create visualization network
vtkSphereSource sphere;
sphere.SetRadius(0.75);
vtkPolyMapper mapper;
mapper.SetInput(sphere.GetOutput());
vtkActor actor;
actor.SetMapper(mapper);
actor.GetProperty()->SetColor(1,0.39,0.28);
// render sphere
aren->AddActors(&actor);
aren->SetBackground(.1,.2,.4);
renWin->Render();
iren->Start();
}